package tax;

import java.util.Scanner;

public class MagicNubser {
    public static void main(String[] args) {
        System.out.println("请输入合法成绩：");
        Scanner scanner = new Scanner(System.in);
        //System.out.println("scanner.hasNextDouble() = " + scanner.hasNextDouble());
//        while (scanner.hasNextDouble()) {
//           // Scanner scanner1 = new Scanner(System.in);
//            double b = scanner.nextDouble();
//           if (b < 60){
//                System.out.println("不合格！补考");
//            }else if (b > 90) {
//                System.out.println("你的成绩是A");
//            } else if (70 <= b && b <= 90) {
//               System.out.println("你的成绩是B");
//           }else if (60 <= b && b < 70) {
//               System.out.println("你的成绩是C");
//           }
//        }
      do {
            // Scanner scanner1 = new Scanner(System.in);
            double b = scanner.nextDouble();
            if (b < 60){
                System.out.println("不合格！补考");
            }else if (b > 90) {
                System.out.println("你的成绩是A");
            } else if (70 <= b && b <= 90) {
                System.out.println("你的成绩是B");
            }else if (60 <= b && b < 70) {
                System.out.println("你的成绩是C");
            }
        }while (scanner.hasNextDouble());
    }

    }

